Namespace Producto
Public Class FormaCompuesta
	Inherits Auditoria.Transaccion

	Private vFormaCompuestaId As Integer = -1
	Private vNombre As String = ""
	Private vSimpleID As Integer = -1
	Private vSimpleNombre As string =""
	Private vStandar As Integer = -1

	Public Property FormaCompuestaId() As Integer
		Get
			Return vFormaCompuestaId
		End Get
		Set(ByVal Value As Integer)
			vFormaCompuestaId = Value
		End Set
	End Property

	Public Property Nombre() As String
		Get
			Return vNombre
		End Get
		Set(ByVal Value As String)
			vNombre = Value
		End Set
	End Property

	Public Property SimpleID() As Integer
		Get
			Return vSimpleID
		End Get
		Set(ByVal Value As Integer)
			vSimpleID = Value
		End Set
	End Property

	Public Property SimpleNombre() as string
		Get
			Return vSimpleNombre
		End Get
		Set(ByVal Value As string)
			vSimpleNombre = Value
		End Set
	End Property

	Public Property Standar() As Integer
		Get
			Return vStandar
		End Get
		Set(ByVal Value As Integer)
			vStandar = Value
		End Set
	End Property

	Sub New()
	End Sub

	Sub New(ByRef FormaCompuestaId As Integer, ByVal Nombre As String, ByVal SimpleID As Integer, ByVal Standar As Integer)
		vFormaCompuestaId = FormaCompuestaId
		vNombre = Nombre
		vSimpleID = SimpleID
		vStandar = Standar
	End Sub

End Class



 Public Class FormaCompuestaCol   
 Inherits System.Collections.CollectionBase
Private _enmSortDirection As SortDirection
Public Sub New()
_enmSortDirection = SortDirection.Asc
End Sub
Public Sub Sort(ByVal sortExpression As String, ByVal sortDirection As SortDirection)
InnerList.Sort(New Comparer(sortExpression, SortDirection))
End Sub
Public Sub Sort(ByVal sortExpression As String)
InnerList.Sort(New Comparer(sortExpression, _enmSortDirection))
If _enmSortDirection = SortDirection.Asc Then
_enmSortDirection = SortDirection.Desc
Else
_enmSortDirection = SortDirection.Asc
End If
End Sub
Public Function Add(ByVal obj As FormaCompuesta) As Integer
Return MyBase.List.Add(obj)
End Function
Public Sub AddPrimero(ByVal obj As FormaCompuesta)
MyBase.List.Insert(0, obj)
End Sub
Public ReadOnly Property FormaCompuesta(ByVal Index As Integer) As FormaCompuesta
Get
Return CType(MyBase.List(Index), FormaCompuesta)
End Get
End Property
End Class
end namespace

